﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace TinySkill
{
    //技能对象组件，保存单个技能数据。有特殊编辑器（SkillEditor）
    public class SkillObject : MonoBehaviour
    {
        public int id;

        public config_skill skill
        {
            get
            {
                return Data.GetSkill(id);
            }
        }

        public int selected_frame_index;

        public config_skill_frame selected_frame
        {
            get
            {
                if (skill != null && selected_frame_index >= 0 && selected_frame_index < skill.frames.Length)
                    return skill.frames[selected_frame_index];

                return null;
            }
        }

        public object last_selected_property;

        // Use this for initialization
        void Start()
        {
         
        }

        // Update is called once per frame
        void Update()
        {

        }
    }
}